
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <meta http-equiv="x-ua-compatible" content="ie=edge">
    <meta name="referrer" content="always">
    <link rel="canonical" href="/">

    <meta name="description" content="Dashboard template built with tailwindcss 🛩">

    <title>@yield('title')｜后台管理</title>

    <link rel="stylesheet" href="{{ mix('css/app.css') }}">
    <script src="{{ mix('js/app.js') }}"></script>
    @yield('beforeScript')
</head>
<body>

<div x-data="{ sidebarOpen: false }" class="flex h-screen bg-gray-200 font-roboto">
    <div :class="sidebarOpen ? 'block' : 'hidden'" @click="sidebarOpen = false" class="fixed z-20 inset-0 bg-black opacity-50 transition-opacity lg:hidden"></div>

    <div :class="sidebarOpen ? 'translate-x-0 ease-out' : '-translate-x-full ease-in'" class="fixed z-30 inset-y-0 left-0 w-64 transition duration-300 transform bg-gray-900 overflow-y-auto lg:translate-x-0 lg:static lg:inset-0">
        <div class="flex items-center justify-center mt-8">
            <div class="flex items-center">
                <span class="text-white text-2xl mx-2 font-semibold">商户信息</span>
            </div>
        </div>
        @include('user.layouts._nav')
    </div>
    <div class="flex-1 flex flex-col overflow-hidden">
        @include('user.layouts._header')
        <main class="flex-1 overflow-x-hidden overflow-y-auto bg-gray-200">
            <div class="container mx-auto px-6 py-8">
                <h3 class="text-gray-700 text-3xl font-medium mb-8">@yield('title', '易支付')</h3>
                @yield('content')
            </div>
        </main>
    </div>
</div>
</body>
@yield('afterScript')
@foreach(['success', 'error'] as $msg)
@if(session()->has($msg))
<script>$.message({message: '{{ session()->get($msg) }}', type:"{{ $msg }}"});</script>
@endif
@endforeach
</html>
